package com.dave.admin.component;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * Json web token 配置
 * @author Dave
 */
@Data
@Component
@ConfigurationProperties(value = BossJwtProperties.PREFIX)
public class BossJwtProperties {

    public static final String PREFIX = "boss.jwt";

    /**
     * JWT存储的请求头
     */
    private String tokenHeader;
    /**
     * JWT加解密使用的密钥
     */
    private String secret;
    /**
     * JWT的超期限时间(60*60*24)
     */
    private Long expiration;
    /**
     * JWT负载中拿到开头
     */
    private String tokenHead;
}
